package com.sqx.modules.goodsType.controller;

import com.sqx.common.utils.Result;
import com.sqx.modules.goodsType.entity.GoodsDegree;
import com.sqx.modules.goodsType.service.GoodsDegreeService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @description：TODO
 * @author： qiao
 * @create： 2024/10/14 14:34
 */
@RestController
@RequestMapping("/app/goodsDegree/")
@Api(value = "商品新旧程度相关-用户端", tags = {"商品新旧程度相关-用户端"})
public class AppGoodsDegreeController {

    @Autowired
    private GoodsDegreeService goodsDegreeService;

    @PostMapping("getGoodsDegreeList")
    @ApiOperation("获取商品新旧程度列表")
    public Result getGoodsDegreeList(@ApiParam("页码")Integer page,
                                     @ApiParam("条数")Integer limit,
                                     @ApiParam("商品新旧程度的实体")GoodsDegree goodsDegree) {
        return Result.success().put("data",goodsDegreeService.getGoodsDegreeList(page, limit, goodsDegree));
    }
}
